#include "stm32f10x.h"                  // Device header
#include "OLED.h"
#include "pwm.h"
#include "delay.h"
#include "ic.h"

int main(void)
{
	OLED_Init();
	PWM_Init();
	IC_Init();
	OLED_ShowString(1,1,"Freq:00000HZ");
	PWM_SetCompare1(50);     ///duty=ccr / 100
	PWM_Prescaler(720-1);   //freq=72M/(psc+1)/100 
	while(1)
	{
		OLED_ShowNum(1,6,IC_GetFreq(),5);
	}
}
